package com.base.mapper.voipmapper;

import com.base.po.voip.SelfShopGoods;
import com.base.po.voip.SelfShopGoodsExample;
import com.base.utils.Page;

import java.util.List;
import org.apache.ibatis.annotations.Param;

public interface SelfShopGoodsMapper {
    int countByExample(SelfShopGoodsExample example);

    int deleteByExample(SelfShopGoodsExample example);

    int insert(SelfShopGoods record);

    int insertSelective(SelfShopGoods record);

    List<SelfShopGoods> selectByExample(SelfShopGoodsExample example);
    
    SelfShopGoods selectByPrimaryKey(String id);

    SelfShopGoods selectById(@Param("id") String id);

    List<SelfShopGoods> selectAll();

    List<SelfShopGoods> selectByAll(@Param("page") Page page, @Param("parentid") String parentid,
                                    @Param("shopid") String shopid, @Param("goodstext") String goodstext,
                                    @Param("firstclassify") String firstclassify, @Param("secondclassify") String secondclassify,
                                    @Param("status") Byte status);
    
    List<SelfShopGoods> selectByParentID(@Param("page") Page page, @Param("parentid") String parentid,
                                         @Param("shopid") String shopid, @Param("goodstext") String goodstext,
                                         @Param("firstclassify") String firstclassify, @Param("secondclassify") String secondclassify,
                                         @Param("sname") String sname, @Param("sord") String sord);

    List<SelfShopGoods> selectNew(@Param("parentid") String parentid, @Param("shopid") String shopid);

    int updateByExampleSelective(@Param("record") SelfShopGoods record, @Param("example") SelfShopGoodsExample example);

    int updateByExample(@Param("record") SelfShopGoods record, @Param("example") SelfShopGoodsExample example);
    
    int updateByPrimaryKeySelective(SelfShopGoods record);
    
    int updateByPrimaryKey(SelfShopGoods record);
    
    int countByAll(@Param("parentid") String parentid, @Param("shopid") String shopid,
                   @Param("goodstext") String goodstext, @Param("firstclassify") String firstclassify,
                   @Param("secondclassify") String secondclassify, @Param("status") Byte status);
    
    int countByParentID(@Param("parentid") String parentid, @Param("shopid") String shopid,
                        @Param("goodstext") String goodstext, @Param("firstclassify") String firstclassify,
                        @Param("secondclassify") String secondclassify);

    SelfShopGoods selectsomeById(@Param("goodsid") String goodsid);

    SelfShopGoods selectByIdexceptContext(@Param("id") String id);

    List<SelfShopGoods> selectAllStock();

    int countByID(@Param("goodsid") String goodsid);
}